/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package model;

import java.util.ArrayList;

/**
 *
 * @author Nargisse
 */
public class DocumentsCollection {
    private ArrayList<Document> listDoc;
    
    public DocumentsCollection(){
        this.listDoc = new ArrayList<Document>();
    }
    
    public int addDocument(String name){
        this.listDoc.add(new Document(listDoc.size()+1, name));
        return listDoc.size();
    }
    
    public ArrayList<String> getListValues() {
        ArrayList<String> res = new ArrayList<String>();
        for (Document d : this.listDoc) {
            res.add(d.getValue());
        }
        return res;
    }
}
